import request from '@/utils/request'
import { getServicePath } from '@/api/baseUrlConfig'
const servicePath = getServicePath()

// 查询转接列表
export function queryByCondition (data) {
  return request({
    url: (servicePath?.zhdjProjectServer || '') + '/org-rela-transfer-mgmt/queryByCondition',
    method: 'get',
    params: data
  })
}

// id查询转接详情
export function queryById (data) {
  return request({
    url: (servicePath?.zhdjProjectServer || '') + `/org-rela-transfer-mgmt/queryById/${data.id}`,
    method: 'get',
    params: data
  })
}

// 查询党员列表
export function queryPersonList (data) {
  return request({
    url: (servicePath?.zhdjProjectServer || '') + `/party-member-info-mgmt/queryList`,
    method: 'get',
    params: data
  })
}

// 添加转接人员
export function add (data) {
  return request({
    url: (servicePath?.zhdjProjectServer || '') + `/org-rela-transfer-mgmt/add`,
    method: 'post',
    data
  })
}

// 编辑转接人员
export function edit (data) {
  return request({
    url: (servicePath?.zhdjProjectServer || '') + `/org-rela-transfer-mgmt/edit`,
    method: 'post',
    data
  })
}

// 删除转接人员
export function deleteById (data) {
  return request({
    url: (servicePath?.zhdjProjectServer || '') + `/org-rela-transfer-mgmt/deleteById/${data.id}`,
    method: 'get',
    params: data
  })
}
